Sending Command Strings

Windows provides two functions to send command strings to devices and to query devices for error information:

    The mciSendString1PGC_K2 function sends a command string to an MCI device.

    The mciGetErrorStringY6KOFT function returns the error string corresponding to an error number.

 

The mciSendString function returns zero if successful. If the function fails, the low-order word of the return value contains an error code. You can pass this error code to mciGetErrorString to get a text description of it.